type UserApi = {
    info: () => Promise<any>;
    add: (opts: any) => Promise<any>;
    put: (id:string, opts: any) => Promise<any>;

}

export default <UserApi> {
    info: async () => await getFetchData('/principal/info','get'),
    add: async (opts: any) => await getFetchData('/principal','post', opts),
    put: async (id:string, opts: any) => await getFetchData('/principal?id='+id,'put', opts),
}